Using the picture tool in the dialog editor of your resource editor, you can easily assign a PICT ID to an interface item. But how easy is it to draw the graphic offscreen and blast it back onscreen using CopyBits? PictCDEF makes this kind of picture handling easy, PLUS you get an immense performance boost and lots of built-in goodies.
Features of PictCDEF
• Draws all pictures offscreen first for speed
• Uses ultra-fast CopyBits to draw onscreen
• Draws any picture structure, even JPEG
• Without coding, picts can switch-out when clicked
• Easy-to-use dimming feature
• Easy-to-preset properties:
— Crop
— Clip
— Frame
• Cropped picts may be moved within the graphPort
using a hand cursor
Open Î "D&M, Inc." and click on the phone picture to see the PictCDEF in action. On the mousedown event TrackControl is called. Then, the parent CDEF of the phone item switches the default phone PICT with a red phone PICT as you click and hold down the mouse button. NO SWITCHING CODE was written to make this happen!
See Àá "Var. Codes" for more detail on properties of PictCDEFs.
See Àá "Make a Control" or Àá "Events" for specific info on implementing CyberDEFs in your dev environment.